<style>
.wrapper{
	width: 1080px;
	margin: 0 auto;
	height: 100%;
}
.m-nav{
	display: none;
}
.isMobile{
	display: none;
}
.login .wrapper{
	position: relative;
}
.login-bd{
	position: absolute;
	top: 50%;
	left: 0;
	-webkit-transform: translateY(-50%);
	   -moz-transform: translateY(-50%);
	    -ms-transform: translateY(-50%);
	        transform: translateY(-50%);
	overflow: hidden;
	width: 100%;
	height: 700px;
	-moz-border-radius: 8px;
	     border-radius: 8px;
} 
.login-bd-left{
	float: left;
	display: table;
	padding:20px;
	width: 580px;
	height: 100%;
	background: rgba(49,49,49,.55);
}
.login-bd-left .txt{
	display: table-cell;
	vertical-align: middle;
	font-size: 48px;
	color: #fff;
	text-align: center;
	letter-spacing: 3px;
}
.login-bd-left .txt p{
	font-size: 34px;
	font-family: MicrosoftYaHeiLight;
	color: rgba(255,255,255,.45);
	letter-spacing: -2px;
}
.login-bd-right{
	float: left;
	background: #fff;
	padding: 0 30px;
	-webkit-box-sizing: border-box;
	   -moz-box-sizing: border-box;
	        box-sizing: border-box;
	width: 500px;
	height: 100%;
}
.login-bd-right .hd{
	margin-top:70px;
	text-align: center;
}
.login-bd-right .hd h3{
	margin-top: 20px;
	font-size: 16px;
	color: #232323;
}
.txt-line{
	position: relative;
	text-align: center;
}
.txt-line:before,
.txt-line:after{
	content: '';
	position: absolute;
	top: 50%;
	width: 114px;
	height: 1px;
	background: #1b1b1b;
}
.txt-line:before{
	left: 0;
}
.txt-line:after{
	right: 0;
}
.login-bd-right .bd{
	margin-top: 20px;
}
.login-bd-right .bd li{
	margin-bottom: 15px;
	position: relative;
	
}
.login-bd-right .bd li input{
	padding: 0 15px 0 60px;
	-webkit-box-sizing: border-box;
	   -moz-box-sizing: border-box;
	        box-sizing: border-box;
	display: block;
	width: 100%;
	height: 40px;
	background: none;
	border: none;
	-webkit-transition: all .5s;
	-moz-transition: all .5s;
	transition: all .5s;
	border: solid 1px #949494;
}
.login-bd-right .bd li input:focus{
	border-color: #1b1b1b;
	-moz-border-radius: 0;
	border-radius: 0;
	-webkit-box-shadow: 0 0 10px 0 rgba(255,255,255,.6);
	   -moz-box-shadow: 0 0 10px 0 rgba(255,255,255,.6);
	        box-shadow: 0 0 10px 0 rgba(255,255,255,.6);
}
.login-bd-right .bd li i{
	position: absolute;
	top: 50%;
	left: 22px;
	-moz-transform: translateY(-50%);
	 -ms-transform: translateY(-50%);
	     transform: translateY(-50%);
	-webkit-transform: translateY(-50%);
}
.login-bd-right .bd li:last-child{
	margin-bottom: 0;
}
.login-bd-right .bd .login-btn a{
	display: block;
	width: 100%;
	line-height: 50px;
	-moz-border-radius: 25px;
	     border-radius: 25px;
	background: #10c7d9;
	text-align: center;
	color: #fff;
	font-size: 16px;
	letter-spacing: 2px;
}
.login-bd-right .bd .regst{
	margin-top: 20px;
	text-align: center;
}
.login-bd-right .bd .regst a{
	color: #10c7d9;
}
.login-bd-right .bd .regst span{
	color: #272727;
}
.login-bd-right .ft{
	margin-top: 50px;
	text-align: center;
}
.login-bd-right .ft li{
	display: inline-block;
	margin: 0 5px;
}

.login-bd-right input {
    height: 44px;
}
.form-group{margin-bottom:25px}
</style>
<div class="wrapper">
    <div class="login-bd">
      <div class="login-bd-left">
        <div class="txt">
          <h1 style="font-size:50px">{{pagedata.app.title || '教育培训CRM'}}</h1>
          <p>{{pagedata.app.appset.desc || 'The name of the company'}}</p>
        </div>
      </div>
      <div class="login-bd-right">
        <div class="hd"> <a href="javascript:void(0);"> <img style="height:50px" ng-src="{{tomedia(pagedata.app.image) || '../core/resource/images/ng-logo.png'}}"> </a>
           <h3 class="txt-line" style="font-weight:bold;font-size:22px">{{pagedata.wxauth!=2?'总后台登录':'微信咨询'}}</h3>
        </div>
		<div class="form-group fui-tab" ng-if="pagedata.mobile_code && pagedata.wxauth!=2" style="line-height:2.6;margin-top:40px">
			<a ng-class="{'disabled':pagedata.item.login_type!=2,'active':pagedata.item.login_type==1}" ng-click="pagedata.item.login_type=1;pagedata.wxauth=0">账号{{pagedata.isreg!=1?'登陆':'注册'}}</a>
			<a ng-class="{'disabled':pagedata.item.login_type==2,'active':pagedata.item.login_type==2}" ng-click="pagedata.item.login_type=2;pagedata.wxauth=0">手机{{pagedata.isreg!=1?'登陆':'注册'}}</a>
		</div>
        <div class="bd" ng-if="pagedata.wxauth!=1 && pagedata.wxauth!=2 && pagedata.isreg!=1">
           <div ng-show="pagedata.item.login_type==1" class="form-group">
				<div class="log-form-item">
					<input type="text" ng-model="pagedata.item.name" placeholder="用户名/邮箱/手机号" class="form-control log-input">
					<i class="icon icon-wo1"></i>
				</div>
		   </div>
		   <div ng-show="pagedata.item.login_type==1" class="form-group">
				<div class="log-form-item">
					<input type="password" ng-model="pagedata.item.password" placeholder="输入您的密码" class="form-control log-input">
					<i class="icon icon-mima"></i>
				</div>
		   </div>
		   <div class="form-group" ng-show="pagedata.item.login_type==2">
				<div class="log-form-item">
					<input type="text" ng-model="pagedata.item.mobile" placeholder="输入您的手机号" class="form-control log-input">
					<i class="icon icon-shumashouji"></i>
				</div>
			</div>
		   <div class="form-group input-group" ng-show="pagedata.verify_code">
					<div class="input-group-addon"><i class="fa fa-info"></i></div>
					<input ng-model="pagedata.item.code" class="form-control" style="width:130px;" placeholder="请输入验证码">
					<a href="javascript:;" id="code" ng-click="code_image('imgverify')" style="text-decoration: none"><img id="imgverify" src="../core/resource/images/no_imgcode.png" style="height:44px;" title="点击图片更换验证码"/></a>
			</div>
			<div class="form-group input-group" ng-show="pagedata.item.login_type==2">
					<div class="input-group-addon"><i class="fa fa-info"></i></div>
					<input ng-model="pagedata.item.smscode" class="form-control" style="width:130px;" placeholder="请输入短信验证码">
					<a class="jy-btn jy-btn-default" href="javascript:;" id="sms_code" ng-click="tool.mobile_code({'mobile':pagedata.item.mobile,'imgcode':pagedata.item.code,'check_imgcode':pagedata.verify_code})" style="text-decoration: none;margin:2px 10px;padding:10px 12px">发送验证码</a>
			</div>
            <div class="login-btn" style="margin-top:50px"> <a href="javascript:void(0);" ng-click="pagedata.login()">登录</a> </div>
        </div>
		<div class="bd" ng-if="pagedata.wxauth!=1 && pagedata.wxauth!=2 && pagedata.isreg==1">
			<div ng-show="pagedata.item.login_type==1">
				<div class="form-group">
					<div class="log-form-item">
						<input type="text" ng-model="pagedata.item.name" placeholder="用户名/邮箱/手机号" class="form-control log-input">
						<i class="icon icon-wo1"></i>
					</div>
				</div>
				<div class="form-group">
					<div class="log-form-item">
						<input type="password" ng-model="pagedata.item.password" placeholder="输入您的密码" class="form-control log-input">
						<i class="icon icon-mima"></i>
					</div>
				</div>
				<div class="form-group">
					<div class="log-form-item">
						<input type="password" ng-model="pagedata.item.password1" placeholder="输入重新您的密码" class="form-control log-input">
						<i class="icon icon-mima"></i>
					</div>
				</div>
			</div>
			<div class="form-group" ng-show="pagedata.item.login_type==2">
						<div class="log-form-item">
							<input type="text" ng-model="pagedata.item.mobile" placeholder="输入您的手机号" class="form-control log-input">
							<i class="icon icon-shumashouji"></i>
						</div>
			</div>
			  <div class="form-group input-group" ng-show="pagedata.verify_code">
					<div class="input-group-addon"><i class="fa fa-info"></i></div>
					<input ng-model="pagedata.item.code" class="form-control" style="width:130px;" placeholder="请输入验证码">
					<a href="javascript:;" id="code" ng-click="code_image('imgverify')" style="text-decoration: none"><img id="imgverify" src="../core/resource/images/no_imgcode.png" style="height:44px;" title="点击图片更换验证码"/></a>
			  </div>
			 <div class="form-group input-group" ng-show="pagedata.item.login_type==2">
					<div class="input-group-addon"><i class="fa fa-info"></i></div>
					<input ng-model="pagedata.item.smscode" class="form-control" style="width:110px;" placeholder="请输入验证码">
					<a class="jy-btn jy-btn-default" href="javascript:;" id="sms_code" ng-click="tool.mobile_code({'mobile':pagedata.item.mobile,'imgcode':pagedata.item.code,'check_imgcode':pagedata.verify_code})" style="text-decoration: none;margin:2px 10px;padding:10px 12px">发送验证码</a>
		    </div>
			<div ng-if="pagedata.open == 1" class="form-group">
							<div class="log-form-item">
								<input type="text" ng-model="pagedata.item.incode" placeholder="请填写邀请码" class="form-control log-input">
								<i class="icon icon-wo1"></i>
							</div>
			</div>
            <div class="login-btn"> <a href="javascript:void(0);" ng-click="post(pagedata.item,'core/home.appregister/register/');code_image('imgverify');">注册</a> </div>
        </div>
		<div class="bd" ng-if="pagedata.wxauth==1">
				<div class="form-group log-qrcode-cont" style="margin-top:20px">
					<div class="wap-qrcode-image" id="login_ewm" style="width:160px;margin:0 auto">
					</div>
					<div class="text"><i class="icon icon-saoyisao1"></i> 打开微信，扫一扫登录</div>
				</div>
		</div>
		<div class="bd" ng-if="pagedata.wxauth==2">
				<div class="form-group log-qrcode-cont" style="width:280px;height:280px;margin-top:35px">
					<div class="wap-qrcode-image" style="width:240px;margin:0 auto">
						<img style="width:240px;" ng-src="{{tomedia(pagedata.app.appset.kfewm)||'../core/resource/images/no-wxapp.png'}}" alt="二维码">
					</div>
				</div>
				<div class="text" style="text-align:center;margin-top:-10px"><i class="icon icon-saoyisao1"></i> 手机扫码加我微信</div>
		</div>
		<div ng-if="pagedata.wxauth!=2" class="other-login-line">
					<div class="fui-cellone" style="padding:15px 3px">
						<div ng-show="pagedata.qq_login" class="fui-cellone-label" style="padding-right:20px">
						<img src="../core/resource/images/icon/qq.png" style="width:22px;height:22px"/>
						<a style="line-height:22px" href="javascript:;" rel="nofollow" target="_blank" ng-click="access_json('core/user.login_domain/qq_login/')">QQ</a>
						</div>
						<div ng-show="pagedata.wechat_login==1" class="fui-cellone-label" style="padding-right:20px">
						<img src="../core/resource/images/icon/wechat.png" style="width:22px;height:22px"/>
						<a style="line-height:22px" href="javascript:;" rel="nofollow" target="_blank" ng-click="access_json('core/user.login_domain/wechat_login/')">微信</a>
						</div>
						<div ng-show="pagedata.wechat_login!=1 && pagedata.wechat_scan_login==1" class="fui-cellone-label" style="padding-right:20px">
						<img src="../core/resource/images/icon/wechat.png" style="width:22px;height:22px"/>
						<a style="line-height:22px" href="javascript:;" ng-click="pagedata.towechat_scan_login();">微信</a>
						</div>
						<div ng-show="pagedata.wxwork_scan_login" class="fui-cellone-label">
						<img src="../core/resource/images/icon/qq.png" style="width:22px;height:22px"/>
						<a style="line-height:22px" href="javascript:;" rel="nofollow" target="_blank" ng-click="access_json(pagedata.wxwork_scan_login)">企业微信</a>
						</div>
						<div class="fui-cellone-info"></div>
						<div ng-if="pagedata.isreg!=1" class="fui-cellone-remark">
							<a class="action" href="javascript:;" ng-click="pagedata.isreg=1"><i class="fa fa-chevron-circle-right syscolor" style="font-size:16px"> 去注册</i></a>
						</div>
						<div ng-if="pagedata.isreg==1" class="fui-cellone-remark">
							<span>已有账号？</span> <a class="action" href="javascript:;" ng-click="pagedata.isreg=0"><i class="fa fa-chevron-circle-right syscolor" style="font-size:16px"> 去登录</i></a>
						</div>
					</div>
		</div>
        <div class="ft c" style="color:#666">
			<div class="c" style="width:100%">
            <span> 咨询电话 </span>
            <span> {{pagedata.app.appset.tel||'400-188-XXXX'}} </span>
			</div>
      </div>
    </div>
</div>
<script>
scope.code_image('imgverify',true);
scope.pagedata.towechat_scan_login=function(){
	var url=scope.tool.manage_url('core/user.login/wxauth_check/session_id='+scope.pagedata.session_id,true);
	scope.tool.qr(url,'login_ewm');
	scope.pagedata.wxauth=1;
	scope.tool.wechat_login(function(res){
		if(!res.message || !res.message.openid){
			scope.message('获取openid失败，微信登陆失败！');
		}
		if(res.to_uid==scope.pagedata.session_id){
			scope.pagedata.item.openid=res.message.openid;
			scope.post(scope.pagedata.item,'core/user.login/wechat_scan_login/');
		}
	});
}
scope.pagedata.login=function(){
	scope.post(scope.pagedata.item,'core/home.applogin/login/');
}
$("body").keydown(function () {
	if (window.event.keyCode==13) {
		scope.pagedata.login();
	}
});
</script>